package com.mdoya.service;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.mdoya.domain.Category;
import com.mdoya.query.CategoryQuery;

import java.util.List;

/**
 * @author mdoya
 * @version 1.0
 * @description:
 */
public interface CategoryService {
    Integer insert(Category category);
    Integer deleteById(Long categoryId,Integer type);
    Integer updateById(Category category);
    IPage<Category> selectPage(CategoryQuery categoryQuery);

    /**
     *  根据type类型查询
     * @param type
     * @return
     */
    List<Category> selectTypeCategoryList(Integer type);

    /**
     *
     * @param id 对应表的字段
     * @return
     */
    Category selectTypeCategory(Long id);

    /**
     *  首页查询所有分类类型
     * @return
     */
//    List<Category> findTypeAll();
}
